<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
    <style>
        .box{
            width: 450px;
            height: 450px;
            margin: 50px auto;
            border-radius: 50%;
            display: flex;
            box-shadow: 0 0 0 3px black inset;
            align-items: center;
            justify-content: center;
            position: relative;
            background-image: url(./img/timg.png);
            background-size: 100%;
        }
        /* .line1{
            width: 450px;
            height: 1px;
            background-color: black;
            margin-top: -11px;
        }
        .line2{
            width: 1px;
            height: 450px;
            background-color: black;
            margin-left: -5px;
        }
        .line1,.line2{
            font-weight: bold;
            font-size: 20px;
        }
        .line1>span{
            float: right;
        }
        .line2>span{
            line-height: 825px;
        } */
        .ball{
            width: 15px;
            height: 15px;
            border-radius: 50%;
            z-index: 10;
            /* background-color: black; */
            display: flex;
            align-items: center;
            justify-content: center;
        }
        .ball::before{
            border-radius: 50%;
            content: '';
            width: 5px;
            height: 5px;
            position: absolute;
            z-index: 100;
            /* background-color: white; */
        }
        .box>div{
            position: absolute;
        }

        #hour{
            /* border-radius: 100% 200%; */
            width: 44px;
            height: 120px;
            margin-top: -50px ;
            transform-origin: center 109px;
            /* background-color: black; */
            background-image: url(./img/hour.png)
        }
        #min{
            /* border-radius: 200% 200%; */
            width: 22px;
            height: 160px;
            margin-top: -71px ;
            transform-origin:center 149px;
            /* background-color: rgb(102, 102, 102); */
            background-image: url(./img/min.png);
        }
        #sec{
            /* border-radius: 200% 200%; */
            width: 37px;
            height: 200px;
            margin-top: -91px ;
            transform-origin: center 190px;
            /* background-color: rgb(46, 46, 46); */
            background-image: url(./img/sec.png);
            z-index: 100;
            /* position: relative; */
        }
    </style>
</head>
<body>
    <a href="./txt/summertimerecord.txt">click</a>
    <div class="box">
        <!-- <div class="line1">9 <span>3</span></div>
        <div class="line2">0 <span>6</span></div> -->
        <div class="ball"></div>
        <div id="hour"></div>
        <div id="min"></div>
        <div id="sec"></div>
    </div>

    <script>
        var hour = document.getElementById('hour');
        var min = document.getElementById('min');
        var sec = document.getElementById('sec');
        // hour.style.transform = 'rotate('+210+'deg)';

        var time1 = ()=>{
            date = new (Date);
            h = Math.floor(((date.getHours() - 12) + (date.getMinutes() / 60))*100)/100;
            m = Math.floor(date.getMinutes());
            s = Math.floor(date.getSeconds()+1);
            console.log(h,m,s)
            hour.style.transform = 'rotate(' + (30 * h) + 'deg)';
            min.style.transform = 'rotate(' + (6 * m) + 'deg)';
            sec.style.transform = 'rotate(' + (6 * s) + 'deg)';
        }
        time1();
        setInterval(time1, 1000);
       
    </script>
</body>
</html>